#!/usr/bin/ruby -w
# Activeresource-event-manipulation.rb

require 'activesupport/lib/active_support'
require 'activeresource/lib/active_resource'

# Define a model for the objects exposed by the site
class Event < ActiveResource::Base
self.site = 'http://localhost:3000/'
end

def show_events
events = Event.find :all # GET /events.xml
puts "evento(s):"
events.each do |event|
puts " #{event.name}"
end
end

puts
show_notes